/*
 * Copyright (c) 2006-2021, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2021-04-05     andy       the first version
 */
#ifndef APPLICATIONS_DEVDATABASE_H_
#define APPLICATIONS_DEVDATABASE_H_

#include <rtthread.h>

#include "modbus485.h"




#define SOIL_SENSOR_LV_MAX     5   //土壤墒情站最大层数


#define WIFI_DEF_SSID           "xjaujsj"
#define WIFI_DEF_PASSWD         "1223334444"


#define WIFI_CONFIG_FILE        "/wificonfig.ini"        //WIFI SSID and password, split by ','
#define WIFI_CONFIG_MINLEN      8                        //WIFI 配置参数最小字节数
#define WIFI_CONFIG_LEN         20                       //WIFI 配置buffer长度
extern char g_wifi_SSID[WIFI_CONFIG_LEN];               //从文件系统读出的SSID
extern char g_wifi_PASSWD[WIFI_CONFIG_LEN];             //从文件系统读出的PASSWORD




extern uint16_t usMBCRC16( uint8_t * pucFrame, uint16_t usLen );


extern rt_err_t fs_WIFI_CONFIG_reload(void);          //reload wifi configuration from file system


#endif /* APPLICATIONS_DEVDATABASE_H_ */
